<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@taglib prefix="s" uri="/struts-tags"%>
<html lang="en">
  <head>
    <meta charset="utf-8">
    <title>超市管理系统</title>
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">

    <!-- Le styles -->
    <link href="./css/bootstrap.css" rel="stylesheet">
    <style type="text/css">
      body {
        padding-top: 60px;
        padding-bottom: 40px;
      }
      .sidebar-nav {
        padding: 9px 0;
      }
    </style>
    <link href="./css/bootstrap-responsive.css" rel="stylesheet">

    <!-- Le HTML5 shim, for IE6-8 support of HTML5 elements -->
    <!--[if lt IE 9]>
      <script src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script>
    <![endif]-->

    <!-- Le fav and touch icons -->
    </head>

  <body>

    <div class="navbar navbar-fixed-top">
      <div class="navbar-inner">
        <div class="container-fluid">
          <a class="btn btn-navbar" data-toggle="collapse" data-target=".nav-collapse">
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
            <span class="icon-bar"></span>
          </a>
		  <a class="brand" href="#">超市商品管理系统</a>
		
          <div class="nav-collapse">
            <ul class="nav">
              <li ><a href="#"><i class="icon-white icon-home"></i>主页</a></li>
              <s:if test="#session.employee.getPermissions()==0" >
			  <li class="active"><a href="newItem.jsp"><i class="icon-white  icon-check"></i>进货</a></li>
			  </s:if>
			  <li><a href="Shipments.jsp"><i class="icon-white  icon-share"></i>出货</a></li>
			  <li><a href="warning.html"><i class="icon-white icon-exclamation-sign"></i>预警</a></li>
			   <s:if test="#session.employee.getPermissions()==0" >
			  <li><a href="info.html"><i class="icon-white icon-info-sign"></i>销售统计</a></li>
			  </s:if>
            </ul>
          </div><!--/.nav-collapse -->
        </div>
      </div>
    </div>

    <div class="container-fluid">
      <div class="row-fluid">
        <div class="span3">
          <div class="well sidebar-nav">
            <ul class="nav nav-list">
              <li class="nav-header">快速访问</li>
              <li class="active"><a href="#"> <i class="icon-home"></i>主页</a></li>
              <li><a href="#"><i class="icon-book"></i>商品库</a></li>
              <s:if test="#session.employee.getPermissions()==0" >
			  <li><a href="#"><i class="icon-signal"></i>销售排行</a></li>
              <li><a href="#"><i class="icon-info-sign"></i>销售统计</a></li>
              </s:if>
              <li class="nav-header">用户</li>
              <li><a href="#"> <i class="icon-user"></i> 个人信息</a></li>
              <li><a href="#"> <i class="icon-cog"></i> 设置</a></li>
			  <li><a href="#"> <i class="icon-list-alt"></i>个人日程</a></li>
              <li class="nav-header">其他</li>
			  <li><a href="#"><i class="icon-flag"></i>帮助</a></li>
            </ul>
          </div><!--/.well -->
        </div><!--/span-->
        <div class="span9">
          <div class="hero-unit">
			  <p>请输入货物的详细信息：</p>
			  <form class="form-item" id="form-item" name="purchasePro" method="POST" action="/Supermarket/purchasePro.action">
				  <table>
					  <tr>
						  <td><b>货号：</b></td><td><input id="input-item-no" name="item.itemNo"></input></td><td><a class="btn btn-primary" id="item-fresh">添加</a></td>
					  </tr>
				  </table>
				  <table id="tb-item-detail" style="display:none;">
					  <tr>
						  <td><b>商品名称：</b></td><td><input id="input-item-name" name="item.name"></input></td>
					  </tr>
					   <tr>
						  <td><b>商品价格：</b></td><td><input id="input-item-price" name="item.price"></input></td>
					  </tr>
					  <tr>
						  <td><b>品牌：</b></td><td><input id="input-item-brand" name="item.brand"></input></td>
					  </tr>
					  <tr>
						  <td><b>厂家：</b></td><td><input id="input-item-factory" name="item.factory"></input></td>
					  </tr>
					  <tr>
						  <td><b>厂址：</b></td><td><input id="input-item-address" name="item.adress"></input></td>
					  </tr>
					  <tr>
						  <td><b>联系电话：</b></td><td><input id="input-item-tel" name="item.tel"></input></td>
					  </tr>
					  <tr>
						  <td><b>负责员工：</b></td><td><input id="input-item-employee" name="item.employeeId"></input></td>
					  </tr>
				  </table>
				  <p><input class="btn btn-primary btn-large" type="button" value="添加" id="btn-item-submit" name="method:addItem"  style="display:none;"></input></p>
			  </form>
			  <div id="form-input-detail" style="display:none;">
			  		<table>
			  		<tr>
			  			<td>进货日期</td><td><input id="input-item-productionDate" name="purchase.productionDate"></input></td>
			  		</tr>
			  			<tr>
			  			<td>过期日期</td><td><input id="input-item-expiredDate" name="purchase.expiredDate"></input></td>
			  		</tr>
			  			<tr>
			  			<td>数量</td><td><input id="input-item-num" name="purchase.num"></input></td>
			  		</tr>
			  		</table>
			  		 <p><input class="btn btn-primary btn-large" type="button" value="保存" id="btn-item-detail-submit" name="method:addPurchase" ></input></p>
			  </div>
		  </div>
	  </div><!--/span-->
      </div><!--/row-->

      <hr>

      <footer>
        <p>&copy; 2012,Software Engineering,ZUST</p>
      </footer>

    </div><!--/.fluid-container-->
	<!-- modal dialog -->
	<div class="modal fade" id="myModal" style="display:none">
		<div class="modal-header">
			<button class="close" data-dismiss="modal">×</button>
			<h3>登录</h3>
		</div>
		<div class="modal-body">
			<table style="margin-left:100px;">
				<tr>
					<td>用户名：</td>
					<td><input id="input-username"></input></td>
				</tr>
				<tr>
					<td>密码：</td>
					<td><input id="input-password" type="password"></input></td>
				</tr>
		</table>
		</div>
		<div class="modal-footer">
			<a href="#" id="btn-login-action" class="btn btn-primary">登录</a>
		</div>
	</div>

	<script src="./js/jquery-1.7.1.min.js"></script>
	<script src="./js/bootstrap.js"></script>    
	<script src="./js/bootstrap-dropdown.js"></script>
	<script src="./js/bootstrap-modal.js"></script>
	<script src="./js/main.js"></script>
</body>
</html>
<!-- <html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Insert title here</title>
</head>
<body>
成功
<s:property value="#session.employee.getName()"/>
</body>
</html> -->


<!-- 
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<title>Insert title here</title>
</head>
<body>
<s:form action="purchasePro">
<s:textfield label="货号" name="item.itemNo"></s:textfield>
<s:submit value="查询" theme="simple"/>
</s:form>
</body>
</html>
-->